-
Notifications
You must be signed in to change notification settings - Fork 4.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove bulk actions for templates #35997
Conversation
Deleting templates in bulk is still important for testing and theme development, |
Understood, but it probably shouldn't be possible to delete the actual theme files from this view, right? That seems like something that should only be done by interacting with the files directly. |
No, the theme files were never available in this view. |
I think they should be :) #35994 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have tested the pull request and did not see any issues.
Then I will approve this, but shouldn't the same be done for template parts?
Sorry I was too fast there, the tests still needs to pass. |
Thanks for the approval. Just before we merge, I wanted to offer up an illustration of how bulk trashing could be handled once we display theme files here. I share this in the interest of working out whether the trade-off of losing bulk actions for custom templates is definitely the correct one. In the video below, the Search template is the only user-generated template, and consequently the only one that can be deleted. So when I select-all and delete, all the others remain. We could potentially offer a link to documentation explaining why this occurs. trash.mp4Would this be better than removing bulk actions altogether? |
Thanks for your work on this @jameskoster. What about the 404 template in your video that has been edited by a user? Previously, if you deleted a user modified template, it would revert back to the template provided by the theme, which was very useful. Should we allow that user-modified 404 template to be deleted as well for the same functionality, or maybe a "Delete/Clear Customizations" option? |
@ndiego this is currently possible whilst editing the template: But yes, I think it would be useful to enable this on the templates list view as well. |
Yeah, in the future it might be nice. Especially if a user wanted to revert a bunch of templates all at once, i.e. if there is a theme update and they want to make use of the latest template changes. |
Closing this since we're no longer using the wp-admin list view for templates. |
Part of #35994.
If we go ahead and list all templates in Appearance > Templates, the bulk actions may get confusing since some templates can be deleted, others can be reset, and so on.
Since most sites won't have large amounts of templates, and bulk editing templates is an infrequent exercise anyway, it may be simplest to disable bulk editing altogether for now.
This PR removes the bulk actions dropdown, and the checkboxes in the templates table.
Before
After